<?php /*a:2:{s:67:"D:\phpstudy_pro\WWW\git\DSMall\app\admin\view\voucher\priceadd.html";i:1591848701;s:64:"D:\phpstudy_pro\WWW\git\DSMall\app\admin\view\public\header.html";i:1591845922;}*/ ?>
<!DOCTYPE html>
<html>
    <head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <title>DSMall<?php echo htmlentities(lang('system_backend')); ?></title>
        <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
        <link rel="stylesheet" href="<?php echo htmlentities(ADMIN_SITE_ROOT); ?>/css/admin.css">
        <link rel="stylesheet" href="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/js/jquery-ui/jquery-ui.min.css">
        <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/jquery-2.1.4.min.js"></script>
        <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/jquery.validate.min.js"></script>
        <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/jquery.cookie.js"></script>
        <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/common.js"></script>
        <script src="<?php echo htmlentities(ADMIN_SITE_ROOT); ?>/js/admin.js"></script>
        <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/js/jquery-ui/jquery-ui.min.js"></script>
        <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/js/jquery-ui/jquery.ui.datepicker-zh-CN.js"></script>
        <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/perfect-scrollbar.min.js"></script>
        <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/layer/layer.js"></script>
        <script type="text/javascript">
            var BASESITEROOT = "<?php echo htmlentities(BASE_SITE_ROOT); ?>";
            var ADMINSITEROOT = "<?php echo htmlentities(ADMIN_SITE_ROOT); ?>";
            var BASESITEURL = "<?php echo htmlentities(BASE_SITE_URL); ?>";
            var HOMESITEURL = "<?php echo htmlentities(HOME_SITE_URL); ?>";
            var ADMINSITEURL = "<?php echo htmlentities(ADMIN_SITE_URL); ?>";
        </script>
    </head>
    <body>
        <div id="append_parent"></div>
        <div id="ajaxwaitid"></div>







<div class="page">
    <form id="add_form" method="post">
        <table class="ds-default-table">
            <tbody>
            <tr class="noborder">
                <td class="required w120"><label class="validation"><?php echo htmlentities(lang('admin_voucher_price_title')); ?>(<?php echo htmlentities(lang('ds_yuan')); ?>)<?php echo htmlentities(lang('ds_colon')); ?></label></td>
                <td class="vatop rowform"><input type="text" id="voucher_price" name="voucher_price" class="txt" value="<?php echo htmlentities((isset($info['voucherprice']) && ($info['voucherprice'] !== '')?$info['voucherprice']:'')); ?>"></td>
                <td class="vatop tips"></td>
            </tr>
            <tr class="noborder">
                <td class="required"><label class="validation"><?php echo htmlentities(lang('admin_voucher_price_describe')); ?><?php echo htmlentities(lang('ds_colon')); ?></label></td>
                <td class="vatop rowform"><textarea name="voucher_price_describe" rows="6" class="tarea" id="voucher_price_describe"><?php echo htmlentities((isset($info['voucherprice_describe']) && ($info['voucherprice_describe'] !== '')?$info['voucherprice_describe']:'')); ?></textarea></td>
                <td class="vatop tips"></td>
            </tr>
            <tr class="noborder">
                <td class="required"><label class="validation"><?php echo htmlentities(lang('admin_voucher_price_points')); ?><?php echo htmlentities(lang('ds_colon')); ?></label></td>
                <td class="vatop rowform"><input type="text" id="voucher_points" name="voucher_points" class="txt" value="<?php echo htmlentities((isset($info['voucherprice_defaultpoints']) && ($info['voucherprice_defaultpoints'] !== '')?$info['voucherprice_defaultpoints']:'0')); ?>"></td>
                <td class="vatop tips"><?php echo htmlentities(lang('admin_voucher_price_points_tip')); ?></td>
            </tr>
            </tbody>
            <tfoot>
            <tr class="tfoot">
                <td colspan="15"><input class="btn" type="submit" value="<?php echo htmlentities(lang('ds_submit')); ?>"/></td>
            </tr>
            </tfoot>
        </table>
    </form>

</div>

<script>
    //按钮先执行验证再提交表单
    $(function(){
        //页面输入内容验证
        $("#add_form").validate({
            errorPlacement: function(error, element){
                error.appendTo(element.parent().parent().find('td:last'));
            },

            rules : {
                voucher_price_describe: {
                    required : true,
                    maxlength : 255
                },
                voucher_price: {
                    required : true,
                    digits : true,
                    min : 0
                },
                voucher_points: {
                    digits : true
                }
            },
            messages : {
                voucher_price_describe: {
                    required : '<?php echo htmlentities(lang('admin_voucher_price_describe_error')); ?>',
                    maxlength : '<?php echo htmlentities(lang('admin_voucher_price_describe_lengtherror')); ?>'
                },
                voucher_price: {
                    required : '<?php echo htmlentities(lang('admin_voucher_price_error')); ?>',
                    digits : '<?php echo htmlentities(lang('admin_voucher_price_error')); ?>',
                    min : '<?php echo htmlentities(lang('admin_voucher_price_error')); ?>'
                },
                voucher_points: {
                    digits : '<?php echo htmlentities(lang('admin_voucher_price_points_error')); ?>'
                }
            }
        });
    });
</script>